package main

import "fmt"

func main() {
    // 1. 打印输出
    fmt.Println("Hello, Golang!")

    // 2. 变量声明与初始化
    var name string = "Golang"
    age := 10 // 简短声明
    fmt.Printf("Name: %s, Age: %d\n", name, age)

    // 3. 常量
    const pi float64 = 3.14
    fmt.Println("Pi:", pi)

    // 新增：类型推断
    var inferredType = 42
    fmt.Printf("Inferred Type: %T, Value: %v\n", inferredType, inferredType)

    // 新增：零值概念
    var zeroInt int
    var zeroString string
    fmt.Printf("Zero Value of int: %d, Zero Value of string: '%s'\n", zeroInt, zeroString)
}